/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package tools;

/**
 *
 * @author Rezha
 */
public class debug {
    public static void debugCode(Object o){
        System.out.println(o.toString());
    }

    public static byte[] appendByte(byte[] b1,byte[]b2){
        byte[] ret = new byte[b1.length+b2.length];
       System.arraycopy(b1, 0, ret, 0, b1.length);
       System.arraycopy(b2, 0, ret, b1.length, b2.length);
       return ret;
    }

    public static byte[] getPartByte(byte[] src,int startidx,int lenght){
        byte[] ret = new byte[lenght];
        System.arraycopy(src, startidx, ret, 0, lenght);
        return ret;
    }
}
